Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Precompute summation indices for the model expressions #408

Closed
wants to merge 3 commits into from

Conversation

abelsiqueira
Copy link
Member

Pull request details

Describe the changes made in this pull request

To avoid using conditionals inside of summations in the expressions, we precompute them.
We also compute the duration.

List of related issues or pull requests

Closes #294

Collaboration confirmation

As a contributor I confirm

  • I read and followed the instructions in README.dev.md
  • The documentation is up to date with the changes introduced in this Pull Request (or NA)
  • Tests are passing
  • Lint is passing

@abelsiqueira abelsiqueira added the benchmark PR only - Run benchmark on PR label Jan 11, 2024
Copy link
Contributor

github-actions bot commented Jan 11, 2024

Benchmark Results

4af03a0... 4dc6be5... t[4af03a0...]/t[4dc6be5...]
energy_problem/create_model 0.188 h 0.133 h 1.42
energy_problem/input_and_constructor 27.1 s 27.4 s 0.987
time_to_load 7.54 ± 0.52 s 7.47 ± 0.048 s 1.01

Benchmark Plots

A plot of the benchmark results have been uploaded as an artifact to the workflow run for this PR.
Go to "Actions"->"Benchmark a pull request"->[the most recent run]->"Artifacts" (at the bottom).

Copy link

codecov bot commented Jan 11, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (fc8aa6d) 100.00% compared to head (4dc6be5) 99.77%.
Report is 1 commits behind head on main.

Files Patch % Lines
src/create-model.jl 97.82% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##              main     #408      +/-   ##
===========================================
- Coverage   100.00%   99.77%   -0.23%     
===========================================
  Files           10       10              
  Lines          405      446      +41     
===========================================
+ Hits           405      445      +40     
- Misses           0        1       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@abelsiqueira abelsiqueira force-pushed the 294-precompute-summation-indexes branch from 9007b27 to 4dc6be5 Compare January 17, 2024 15:26
@datejada
Copy link
Member

Close it in favor of #407

@datejada datejada closed this Jan 31, 2024
@datejada datejada deleted the 294-precompute-summation-indexes branch January 31, 2024 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
benchmark PR only - Run benchmark on PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Profile the problem solving
2 participants